import 'package:flutter_ncsjqz_getx/generated/json/base/json_convert_content.dart';
import 'package:flutter_ncsjqz_getx/model/submit_order_entity.dart';

SubmitOrderEntity $SubmitOrderEntityFromJson(Map<String, dynamic> json) {
	final SubmitOrderEntity submitOrderEntity = SubmitOrderEntity();
	final String? msg = jsonConvert.convert<String>(json['msg']);
	if (msg != null) {
		submitOrderEntity.msg = msg;
	}
	final int? code = jsonConvert.convert<int>(json['code']);
	if (code != null) {
		submitOrderEntity.code = code;
	}
	final SubmitOrderData? data = jsonConvert.convert<SubmitOrderData>(json['data']);
	if (data != null) {
		submitOrderEntity.data = data;
	}
	return submitOrderEntity;
}

Map<String, dynamic> $SubmitOrderEntityToJson(SubmitOrderEntity entity) {
	final Map<String, dynamic> data = <String, dynamic>{};
	data['msg'] = entity.msg;
	data['code'] = entity.code;
	data['data'] = entity.data?.toJson();
	return data;
}

SubmitOrderData $SubmitOrderDataFromJson(Map<String, dynamic> json) {
	final SubmitOrderData submitOrderData = SubmitOrderData();
	final double? price = jsonConvert.convert<double>(json['price']);
	if (price != null) {
		submitOrderData.price = price;
	}
	final int? orderId = jsonConvert.convert<int>(json['orderId']);
	if (orderId != null) {
		submitOrderData.orderId = orderId;
	}
	final String? orderNo = jsonConvert.convert<String>(json['orderNo']);
	if (orderNo != null) {
		submitOrderData.orderNo = orderNo;
	}
	final dynamic? couponId = jsonConvert.convert<dynamic>(json['couponId']);
	if (couponId != null) {
		submitOrderData.couponId = couponId;
	}
	final int? taskType = jsonConvert.convert<int>(json['taskType']);
	if (taskType != null) {
		submitOrderData.taskType = taskType;
	}
	final int? executeTime = jsonConvert.convert<int>(json['executeTime']);
	if (executeTime != null) {
		submitOrderData.executeTime = executeTime;
	}
	final dynamic? refundId = jsonConvert.convert<dynamic>(json['refundId']);
	if (refundId != null) {
		submitOrderData.refundId = refundId;
	}
	return submitOrderData;
}

Map<String, dynamic> $SubmitOrderDataToJson(SubmitOrderData entity) {
	final Map<String, dynamic> data = <String, dynamic>{};
	data['price'] = entity.price;
	data['orderId'] = entity.orderId;
	data['orderNo'] = entity.orderNo;
	data['couponId'] = entity.couponId;
	data['taskType'] = entity.taskType;
	data['executeTime'] = entity.executeTime;
	data['refundId'] = entity.refundId;
	return data;
}